<template>
  <div class="infoJudge" v-loading="Data.loading">
    <judge-card
      v-for="(item, index) in Data.judgeCardList"
      :key="index"
      :cardItem="item"
    />
  </div>
</template>

<script setup>
import judgeCard from "./judgeCard.vue";

import { getGameJudgeCard } from "@/service/youxiaData";
import { onMounted, reactive } from "vue";
const Data = reactive({
  judgeCardList: [],
  loading: false,
});
onMounted(() => {
  getGameJudgeCardData();
});

const getGameJudgeCardData = async () => {
  Data.loading = true;
  const res = await getGameJudgeCard();
  Data.judgeCardList.push(res.data[0]);
  Data.judgeCardList.push(res.data[1]);
  Data.loading = false;
};
</script>

<style scoped lang="less">
.infoJudge {
  display: flex;
  height: 450px;
  flex-direction: column;
  justify-content: space-between;
  margin-right: 10px;
}
</style>
